#include<stdio.h>
void send(int n)
{
    if (n == 1)
        printf("  *   ");
    if (n == 2)
        printf(" * *  ");
    if (n == 3)
        printf("* * * ");
}
int main()
{
    int a;
    while (scanf("%d", &a) != EOF)
    {
        for (int i = 1; i <= a; i++)
        {
            for (int j = 1; j <= 3; j++)
            {
                for (int n = 1; n <= a - i; n++)
                    printf("   ");
                for (int m = 1; m <= i; m++)
                    send(j);
                printf("\n");
            }

        }
        for (int i = 1; i <= a; i++)
        {
            for (int j = 1; j <= 3 * a - 1; j++)
                printf(" ");
            printf("*\n");
        }
    }
    return 0;
}